package top.chenfu.aop;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.context.annotation.EnableAspectJAutoProxy;

/**
 * @Auther chenfu
 * @2019/11/6 11:00
 * @Desc
 */
@SpringBootApplication
//@EnableAspectJAutoProxy
public class AopApp {

    public static void main(String[] args) {
        ConfigurableApplicationContext app = SpringApplication.run(AopApp.class, args);
        Business business = (Business) app.getBean("business");
        Object run = business.run(1001);
        System.out.println(run);
    }

}
